home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 23
/
Aminet 23 (1998)(GTI - Schatztruhe)[!][Feb 1998].iso
/
Aminet
/
dev
/
basic
/
EFMUILibSrc.lha
/
EFMUILibSrc
/
mdl.asc
< prev
next >
Wrap
Text File
|
1997-11-29
|
1KB
|
57 lines
;mdl.bb2 --- MakeDefLibs
;Based on makedeflibs.bb2
;(c) 1997 Vivid Imagination
DEFTYPE.l
If WriteFile(0,"blitz2:deflibs")=0
NPrint "Error creating blitz2:deflibs":End
EndIf
l.l=Lock_("blitzlibs:",-2)
If l=0
NPrint "Error 'locking' blitzlibs:":End
EndIf
e.l=AllocMem_(260,1)
e2.l=AllocMem_(260,1)
Examine_ l,e
While ExNext_(l,e)
If Peek.l(e+4)>=0
d$="blitzlibs:"+Peek$(e+8)
l2=Lock_(&d$,-2)
If l2=0
NPrint "Error 'locking' ",d$:UnLock_ l:CloseFile 0:KillFile "blitz2:deflibs"
Goto freemem
EndIf
Examine_ l2,e2
While ExNext_(l2,e2)
If Peek.l(e2+4)<0 ;file?
f$=LCase$(Peek$(e2+8))
If Right$(f$,5)<>".info"
f$=d$+"/"+f$
If ReadFile(1,f$)
FileInput 1:FileOutput 0
Print Mkl$(Lof(1))
Print Inkey$(Lof(1))
CloseFile 1:DefaultOutput
Else
NPrint "Error reading file ",f$
UnLock_ l:UnLock_ l2:CloseFile 0:KillFile "blitz2:deflibs"
Goto freemem
EndIf
EndIf
EndIf
Wend
UnLock_ l2
EndIf
Wend
FileOutput 0:Print Mkl$(0):DefaultOutput
UnLock_ l
CloseFile 0
freemem:FreeMem_ e,260:FreeMem_ e2,260